const http = uni.$u.http
function getConfig(config) {
    return {
        ...config,
        header: {
            Accept: 'application/json'
        }
    }
}
// post请求，获取菜单
export default {
    bannerList: (config = {}) => http.get('/banner/list', ),
    register: (data, config = {}) => http.post('/member', data),
    login: (data, config = {}) => http.post('/member/login', data),
    // 个人信息
    getMemberInfo: (data, config = {}) => http.get('/member/' + data.id, ),
    // 修改个人信息
    updateMemberInfo: (data, config = {}) => http.put('/member/' + data.id, data),
    // 鱼种
    fishList: (config = {}) => http.get('/fish/list', ),
    // 路亚
    lureList: (config = {}) => http.get('/lure/list', ),
    // 鱼获列表
    fishCatchList: (data, config = {}) => http.get('/fishCatch/list', data),
    // 添加鱼获
    createFishCatch: (data, config = {}) => http.post('/fishCatch', data),
    // 删除鱼获
    deleteFishCatch: (data, config = {}) => http.delete('/fishCatch/' + data.id),
    // 花费列表
    costList: (data,config = {}) => http.get('/cost/list',data ),
    // 添加花费
    createCost: (data, config = {}) => http.post('/cost', data),
    // 删除花费
    deleteCost: (data, config = {}) => http.delete('/cost/' + data.id),
    // 打龟列表
    turtleList: (data, config = {}) => http.get('/turtle/list',data ),
    // 添加打龟
    createTurtle: (data, config = {}) => http.post('/turtle', data),
    // 删除打龟
    deleteTurtle: (data, config = {}) => http.delete('/turtle/' + data.id),
    // 提交一起玩
    createPlay: (data, config = {}) => http.post('/play', data),
    // 一起玩列表
    playList: (config = {}) => http.get('/play/list', ),
    // 个人数据
    memberData: (config = {}) => http.get('/member/data', ),
    // 朋友圈列表
    friendList: (config = {}) => http.get('/friend/list', ),

    // 我的解决鱼种
    getMyFishList: (data, config = {}) => http.get('/member/fish', data),
    // 我的解决路亚
    getMyLureList: (data, config = {}) => http.get('/member/lure', data),
    // 查看每日考勤数据
    getAttendance: (data, config = {}) => http.get('/member/day', data),
    // 排名数据
    getRank: (data,config = {}) => http.get('/data/rank',data ),
    // 月度、年度统计
    getTotal: (data,config = {}) => http.get('/data/total',data ),
}